//============================================================================
//
//  Pipeline.h
//  
//  Created By Jeromy Stroh 2009
//
//  Adapted to use DXUT with DirectX 9 / 11 by David Teeder 2010.
//
//============================================================================
#pragma once

struct ID3D11InputLayout;

namespace d3d11
{
	class Pipeline
	{
	public:
		Pipeline();
		~Pipeline();

		void CreateVertexShader(LPCWSTR vertexShaderPath, LPCSTR entryFunction);
		void PushVertexData(VertexData::DataType type, DXGI_FORMAT format, uint size);
		void CreateInputLayout();
		void CreatePixelShader(LPCWSTR pixelShaderPath, LPCSTR entryFunction);
		void EnablePipeline();

	private:		
		IDirect3DDevice9	*m_pD3DDevice9;
		ID3D11Device		*m_pD3DDevice11;
		Shader				*m_pVertexShader;		
		VertexDecl			*m_pVertexDecl;
		ID3D11InputLayout	*m_pVertexLayout;
		Shader				*m_pPixelShader;		
		UINT				*m_pStride;
	};
}
